<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>个人信息管理</title>
<!--    引入jQuery-->
    <script src="https://cdn.bootcdn.net/ajax/libs/jquery/3.7.1/jquery.min.js"></script>
</head>
<body>
<button id="view-info">查看个人信息</button>
<button id="edit-info">修改个人信息</button>

<!-- 显示个人信息 -->
<div id="user-info" style="display:none;">
    <p>ID: <span id="user-id"></span></p>
    <p>Username: <span id="username"></span></p>
    <p>Password: <span id="password"></span></p>
    <p>Login Name: <span id="loginname"></span></p>
    <p>Head Image: <img id="headimg" alt="User Avatar" /></p>
</div>

<!-- 模态框：用于修改个人信息 -->
<div id="edit-modal" style="display:none;">
    <h2>修改个人信息</h2>
    <form id="edit-form">
<!--        隐藏 id-->
        <input type="hidden" id="edit-id" />
        <p>Username: <input type="text" id="edit-username" /></p>
        <p>Password: <input type="password" id="edit-password" /></p>
        <p>Login Name: <input type="text" id="edit-loginname" /></p>
        <p>Head Image URL: <input type="text" id="edit-headimg" /></p>
        <button type="submit">保存修改</button>
    </form>
</div>

<script src="js/app.js"></script>
</body>
</html>
